package org.apache.ibatis.datasource.pooled;

import org.apache.ibatis.datasource.unpooled.UnpooledDataSourceFactory;

/**
 * PooledDataSourceFactory继承了UnpooledDataSourceFactory，但并没有覆盖setProperties()方法和getDataSource()方法。
 * 两者唯一的区别是PooledDataSourceFactory的构造函数会将其dataSource字段初始化为PooledDataSource对象。
 *
 * @author Clinton Begin
 */
public class PooledDataSourceFactory extends UnpooledDataSourceFactory {

    /**
     * 构造函数将其dataSource字段初始化为PooledDataSource对象
     * 数据源(连接池)
     */
    public PooledDataSourceFactory() {
        this.dataSource = new PooledDataSource();
    }

}
